package com.zj.z11select.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.zj.z11select.entity.User;
import javax.validation.constraints.NotNull;
import org.apache.ibatis.annotations.Param;

/**
 * <p>
 * 用户信息表  Mapper 接口
 * </p>
 *
 * @author ZHOUJIE
 * @since 2021-07-06
 */
public interface UserMapper extends BaseMapper<User> {

    /**
     * id 查询
     * @param userId 用户ID
     * @return 用户信息
     */
    User selectUserById(@Param("userId")  @NotNull Integer userId);

    /**
     * 用户名查询
     * @param username 用户名
     * @return 用户信息
     */
    User selectUserByUserName(@Param("username") @NotNull String username);
}
